import request from '../utils/request'

/**
 * 用户注册
 * @param user 
 */
export const register = (user:any) => {
  return request({
    url: '/api/register',
    method: 'post',
    data: user
})
}

/**
 * 登录
 * @param user 
 * @returns 
 */
export const login = (user: any) => {
  return request({
    url: '/api/login',
    method: 'POST',
    data: user,
  })
}
